open(BUFF,"TruSeq_exome_targeted_regions.hg19.bed.chr") or die "no file found TruSeq_exome_targeted_regions.hg19.bed.chr\n";
open(WRBUFF,">Illumina_Probes_chr22.txt") or die "not able to write the file S03723424_Probes_chr22.txt\n";
print WRBUFF "TargetID\tProbeID\tSequence\tReplication\tStrand\tCoordinates\n";

while(<BUFF>)
{
	chomp($_);
	if($_ =~ m/^chr22/)
	{
		@array=split("\t",$_);
		@gene=split(":",$array[3]);
		print $gene[2]."\n";
	}	
}
